﻿@{
    Layout = null;
    Response.ContentType = "text/javascript";
}

var systemTitle = 'Ideas to realize';
var systemVersion = '@ViewBag.Version';
var loginName = ' | Logged in as <a id="settings-link" href="/Home/Settings" title="Settings for @ViewBag.UserFullname">@ViewBag.UserFullname</a>';
var usersFullname = '@ViewBag.UserFullname';

var getMainToolbarButtons = function () {
    return [
        @if (User.IsInRole("Administrator"))
        {
            <text>
            { xtype: 'button', text: 'Administration', scale: 'large', iconCls: 'icon32_settings', action: 'administration', cls: 'large-text' },
            </text>
        }
        {xtype: 'button', text: 'Dashboard', scale: 'large', iconCls: 'icon32_home', action: 'dashboard', cls: 'large-text' },
        { xtype: 'button', text: 'News and challenges', scale: 'large', iconCls: 'icon32_info', action: 'news', cls: 'large-text' },
        { xtype: 'button', text: 'My deviations', scale: 'large', iconCls: 'icon32_properties', action: 'myproposals', cls: 'large-text' },
        // { xtype: 'button', text: 'Handling cases', scale: 'large', iconCls: 'icon32_edit-page', action: 'cases', cls: 'large-text' },
        // { xtype: 'button', text: 'Follow up', scale: 'large', iconCls: 'icon32_list', action: 'followups', cls: 'large-text' },
        // { xtype: 'button', text: 'Search', scale: 'large', iconCls: 'icon32_find', action: 'search', cls: 'large-text' },
        { xtype: 'tbfill' },
        //   { xtype: 'button', text: 'Help', scale: 'large', iconCls: 'icon32_help-book', action: 'help', cls: 'large-text' },
        { xtype: 'button', text: 'Logout', scale: 'large', iconCls: 'icon32_exit', action: 'logout' }
    ];
}; 